<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>盒子模型练习</title>
    <style>
        #d1 {
            width: 100px;
            height: 100px;
            background-color: red;
            margin-left: 25px;
            margin-top: 25px;
            overflow: hidden;
        }

        div > div {
            width: 50px;
            height: 50px;
            background-color: blue;
            margin: 25px 0 0 25px;
        }

        #d2 {
            width: 100px;
            height: 100px;
            border: 5px solid green;
            border-radius: 5px;
            margin-left: 125px;
            padding: 50px 0 0 50px;
            box-sizing: border-box;
        }
    </style>
</head>
<body>
<div id="d1">
    <div></div>
</div>

<div id="d2">哈喽</div>

</body>
</html>